package com.cyys.controller;

import com.cyys.entity.Store;
import com.cyys.entity.Takeout;
import com.cyys.response.Result;
import com.cyys.service.TakeoutService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author Administrator
 * @description TakeoutController
 * @date 2022-06-07 10:31
 */
@RestController
@RequestMapping("/Takeout")
public class TakeoutController {

    @Autowired
    private TakeoutService takeoutService;

    @GetMapping("/TakeoutList")
    public Result TakeoutList(Integer cg_id){
        List<Takeout> list = takeoutService.listById(cg_id);
        return Result.ok().data("list",list);
    }


}
